package cn.edu.seu.ssny.dao;

import cn.edu.seu.ssny.dao.support.IBaseDao;
import cn.edu.seu.ssny.entity.SelfControllerImage;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;

@Repository
public interface ISelfControllerImageDao extends IBaseDao<SelfControllerImage, Integer> {

    /**
     * 根据项目id找到项目自控策略图
     *
     * @param projectId
     * @return
     */
    @Query(value = "select * from tb_self_controller_image where project_id=?1 and isdeleted=0 ", nativeQuery = true)
    SelfControllerImage findByProjectId(Integer projectId);
}
